
#xml2sql test
print '==================Beginning xml2sql test=================='
from database import xml2sql

testfile = '../../test_files/test.xml'
print xml2sql.convert(testfile)

print '==================Beginning ssearch test=================='
from utilities import ssearch
left_bounds = ['AUG','CTA','TAT', 'UGC']
right_bounds = ['TATTA','AUAAUA','UAAUA']
seq = 'AUTCUTGUATAUGCTATUGAUTTUAGUCCUGTUCATATTAAUAUATUATTAAACCTTACCTUUTT'
l,r = ssearch.lbbox(seq, left_bounds, right_bounds, 19, 30)
print 'Left index: '+str(l)+', Right index: '+str(r)
print seq[l:r]
print ssearch.search_for_uniques(seq, right_bounds)
print ssearch.search_for_uniques(seq, ['AAAAA','CTU'])